using System;
using System.Collections.Generic;
using System.ComponentModel.DataAnnotations;
using System.ComponentModel.DataAnnotations.Schema;
using System.Linq;
using System.Resources;
using System.Runtime.Serialization;
using System.Text;
using System.Threading.Tasks;

namespace KPIS.GERP.Models.BGM
{
	[Table("bgm_strategy_data_list"), DataContract]
    public class StrategyDataList
    {
        public StrategyDataList()
        {
            //this.StrategyDataMappings = new HashSet<StrategyDataMapping>();
        }

		[Key, DatabaseGenerated(DatabaseGeneratedOption.Identity)]
		[DataMember, Display(Name = "BgmStratListId", ResourceType = typeof(Resources.StrategyDataListResource))]
		[Column("bgm_strat_list_seq", TypeName="int")]
        public int BgmStratListId { get; set; }

		[DataMember, Display(Name = "BgmStratListCode", ResourceType = typeof(Resources.StrategyDataListResource))]
		[Column("bgm_strat_list_code", TypeName="ntext")]
        public string BgmStratListCode { get; set; }

		[DataMember, Display(Name = "BgmStratListName", ResourceType = typeof(Resources.StrategyDataListResource))]
		[Column("bgm_strat_list_name", TypeName="ntext")]
        public string BgmStratListName { get; set; }

		[DataMember, Display(Name = "BgmStratListDescr", ResourceType = typeof(Resources.StrategyDataListResource))]
		[Column("bgm_strat_list_descr", TypeName="ntext")]
        public string BgmStratListDescr { get; set; }

		[ForeignKey("BgmStratType")]
		[DataMember, Display(Name = "BgmStratTypeId", ResourceType = typeof(Resources.StrategyDataListResource))]
		[Column("bgm_strat_type_seq", TypeName="int")]
        public Nullable<int> BgmStratTypeId { get; set; }

		[DataMember, Display(Name = "GfmisCode", ResourceType = typeof(Resources.StrategyDataListResource))]
		[Column("gfmis_code", TypeName="ntext")]
        public string GfmisCode { get; set; }

		[DataMember, Display(Name = "YearStart", ResourceType = typeof(Resources.StrategyDataListResource))]
		[Column("year_start", TypeName="int")]
        public Nullable<int> YearStart { get; set; }

		[DataMember, Display(Name = "YearEnd", ResourceType = typeof(Resources.StrategyDataListResource))]
		[Column("year_end", TypeName="int")]
        public Nullable<int> YearEnd { get; set; }

        //[DataMember]
        //public virtual ICollection<StrategyDataMapping> StrategyDataMappings { get; set; }

        [DataMember]
        public virtual MasStrategyType BgmStratType { get; set; }



        #region RecordStatus

        [DataMember, Display(Name = "RecordStatus", ResourceType = typeof(SYS.Resources.RecordStatusResource))]
		[Column("record_status", TypeName="ntext")]
        public string RecordStatus { get; set; }

        [DataMember, Display(Name = "CreatedBy", ResourceType = typeof(SYS.Resources.RecordStatusResource))]
		[Column("created_by", TypeName="int")]
        public Nullable<int> CreatedBy { get; set; }

        [DataMember, Display(Name = "CreatedWhen", ResourceType = typeof(SYS.Resources.RecordStatusResource))]
		[Column("created_when", TypeName="datetime2")]
        public Nullable<System.DateTime> CreatedWhen { get; set; }

        [DataMember, Display(Name = "UpdatedBy", ResourceType = typeof(SYS.Resources.RecordStatusResource))]
		[Column("updated_by", TypeName="int")]
        public Nullable<int> UpdatedBy { get; set; }

        [DataMember, Display(Name = "UpdatedWhen", ResourceType = typeof(SYS.Resources.RecordStatusResource))]
		[Column("updated_when", TypeName="datetime2")]
        public Nullable<System.DateTime> UpdatedWhen { get; set; }

        #endregion


    }
}